Cognitoware.Robotics.dll
Structure Pair<T1, T2>
T1: The type contained in the First element.
T2: The type contained in the Second element.
Summary
A structure that holds two elements.
Constructor Summary
Create a pair from the two parameter values.
Method Summary
Equals(Object)
Inherited from System.ValueType
Finalize()
Inherited from System.Object
GetHashCode()
Inherited from System.ValueType
GetType()
Inherited from System.Object
MemberwiseClone()
Inherited from System.Object
Writes the elements of the pair to a string.
Details
This class is modelled after the 'cons' data structure in Lisp.
It is used to group data together that are not grouped together often
enough to need a dedicated class. Note that this is a structure and not
a class.
Constructor Details
public Pair(T1 t1, T2 t2)
Create a pair from the two parameter values.
Parameters:
t1
- The value to be stored in the First element.
t2
- The value to be stored in the Second element.
Method Details
public override String ToString()
Writes the elements of the pair to a string.
Returns:
A string representation of the pair elements.